package com.hyzx.qbasic.admin.domain.service;

import com.hyzx.qbasic.admin.model.po.ProcessInstancePO;
import com.hyzx.qbasic.admin.model.po.ProcessTaskInstancePO;
import com.hyzx.qbasic.admin.model.vo.res.admin.GetProcessStepsRes;

import java.util.List;

/**
 * Created by 黄江华 on 2018/11/22
 */

public interface IProcessFacadeService {

    ProcessInstancePO startProcessInstanceById(int processDefinitionId,
                                               String businessKey,
                                               String startUserId);

    ProcessInstancePO startProcessInstanceByKey(String processConfigKey,
                                                String businessKey,
                                                String startUserId);

    boolean completeTaskById(int taskInstanceId, String assignee, String comment, boolean rejected);

    boolean completeTaskByBusinessKey(String businessKey, String assignee, String comment, boolean rejected);

    boolean completeTask(ProcessTaskInstancePO currentTask, String assignee, String comment, boolean rejected);

    GetProcessStepsRes getProcessSteps(String businessKey);

    boolean batchDeleteProcessInstance(List<String> businessKeyList);

    ProcessInstancePO getProcessInstance(int processInstanceId);

    ProcessInstancePO getProcessInstanceByBusinessKey(String businessKey);
}
